package com.usian.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.usian.user.UserDeptDto;
import com.usian.user.Users;
import org.apache.ibatis.annotations.Select;

import java.util.List;

/**
 * @Author:张永杰
 * @ClassName: UserMapper
 * @Date: 2024/12/11
 * @Description:
 */
public interface UserMapper extends BaseMapper<Users> {
    @Select("select u.*,d.department_name deptName from users u,departments d where u.department_id=d.department_id")
    List<UserDeptDto> findAllUser();
}
